{include file="$g_template/_fronthead.tpl"}
<div id="wrap_3">
		<div id="header">
			<div class="logo"><img src="{$g_image}/logo.png"></div>
			<div class="welcome"><img src="{$g_image}/welcome.png"></div>
		</div>
        
        {include file="$g_template/_mainmenu.tpl"}
        
	<div id="web_content3">
		<div class="title_content_detail">{$title}<br><span style="font-size: 16px;">{$today}</span></div>
		<div class="line"></div>
		<div id="area_title_description">
			<div class="text_title_description">
				<p>
					<span class="text_black_title">Payment ID: </span><span class="text_red_title">{$paymentId}</span>	
				</p>
			</div>
			<div class="text_title_images"><span style="float:right;"><img src="{$g_image}/{$img}"></span></div>
		</div>
			
		<div class="showdetail"><br>
			<table width="700" align="center" border="0" cellpadding="3" cellspacing="0" style="font-size:16px; font-family: sans-serif;">
				<tr>
					<td class="UnderLine"  colspan="2" align="center"><span class="text_black_bold">ข้อมูล Pre-auth</span></td>
				</tr>
				<tr>
					<td  colspan="2" align="left">&nbsp;</td>
				</tr>
				<tr>
					<td align="left"><span style="margin-left:20px;">Pre-auth เลขที่ : {$preauthData.preauth_id}</span></td>
					<td align="left"><span style="margin-left:20px;">วันที่ทำ Pre-auth : {$preauthData.preauth_datetime}</span></td>
				</tr>
				<tr>
					<td align="left"><span style="margin-left:20px;">ชื่อผู้ทำ Pre-auth : {$_profile->user_prename}{$_profile->user_name}&nbsp;{$_profile->user_surname}</span></td>
					<td align="left"><span style="margin-left:20px;">รหัสผู้ใช้ : {$_profile->userid}</span></td>
				</tr>
				<tr>
					<td align="left"><span style="margin-left:20px;">หน่วยงาน : {$_profile->group_name}</span></td>
					<td align="left"><span style="margin-left:20px;">ตำแหน่ง : {$_profile->usertype_description}</span></td>
				</tr>
				<tr>
					<td align="left">&nbsp;</td>
				</tr>
			</table>
			
			<table width="700" align="center" border="0" cellpadding="3" cellspacing="0" style="font-size:16px; font-family: sans-serif;">
				<tr>
					<td class="UnderLine"  colspan="4" align="center"><span class="text_black_bold">ข้อมูลกรมธรรม์</span></td>
				</tr>
				<tr>
					<td colspan="4" align="center">&nbsp;</td>
				</tr>
				<tr>
					<td align="right">ชื่อผู้เอาประกัน :</td>
					<td>{$policyData.name}  {$policyData.surname}</td>
					<td align="right">บัตรประชาชน: </td>
					<td>{$policyData.natid}</td>
				</tr>
				<tr>
					<td align="right">เลขที่่กรมธรรม์ :</td>
					<td>{$policyData.policy_no}</td>
					<td align="right">เลขที่บัตรประกัน :</td>
					<td>{$policyData.cardno}</td>
				</tr>
				<tr>
					<td align="right">วันเริ่มคุ้มครอง :</td>
					<td>{$policyData.effective}</td>
					<td align="right">วันสิ้นสุดความคุ้มครอง :</td>
					<td>{$policyData.expiry}</td>
				</tr>
				<tr>
					<td align="right">แผนความคุ้มครอง :</td>
					<td>{$policyData.plan}</td>
					<td align="right">&nbsp;</td>
					<td>&nbsp;</td>
				</tr>
				<tr>
					<td align="right">Deductible Remain :</td>
					<td>{$policyData.deductible}</td>
					<td align="right">Co-Payment Remain :</td>
					<td>{$policyData.copayment}</td>
				</tr>
				<tr>
					<td colspan="4">&nbsp;</td>
				</tr>
			</table>
			
			<table width="700" align="center" border="0" cellpadding="3" cellspacing="0" style="font-size:16px; font-family: sans-serif;">
				<tr>
					<td class="UnderLine"  colspan="4" align="center"><span class="text_black_bold">ระบุยอดค่าใช้จ่าย</span></td>
				</tr>
				<tr>
					<td  width="25%" align="center">&nbsp;</td>
					<td  width="25%" align="center">&nbsp;</td>
					<td  width="25%" align="center">&nbsp;</td>
					<td  width="25%" align="center">&nbsp;</td>
				</tr>
				<tr>
					<td colspan="4">
						<div class="payment_exp_left">
							<ul>
								<li><label>Accident Date : </label>{$payment_detail.acc_date}</li>
								<li>
									<label>Last Accident : </label>
									<select id="accList" name=accList>
										{foreach from=$accList item=item}
				                        	<option value={$item.acc_date}>{$item.acc_date}</option>
				                         {/foreach}
									</select>
								</li>
								<li><label>Admission Date : </label>{$payment_detail.admis_date}</li>
								<li>
									<label>Cover List : </label>{$payment_detail.payment_type}
								</li>
							</ul>
						</div>
						<div class="payment_exp_right">
							<ul>
								<li><label>Charge : </label>{$payment_detail.charge}&nbsp;บาท</li>
								<li>
									<label>Discount : </label>{$payment_detail.discount}&nbsp;บาท&nbsp;
								</li>
								<li><label>Deductible Remain : </label>{$payment_detail.deductible}&nbsp;บาท</li>
								<li><label>Co-Payment Remain : </label>{$payment_detail.copayment}&nbsp;บาท</li>
								<li><br><label><font color="red">Pre Approved : </font></label>{$payment_detail.pre_approved}&nbsp;บาท</li>
								<li><label><font color="red">Non Covered : </font></label>{$payment_detail.non_covered}&nbsp;บาท</li>
							</ul>
						</div>
					</td>
				</tr>
				<tr>
					<td colspan="4">&nbsp;</td>
				</tr>
				<tr>
					<td colspan="4" align="left">สาเหตุการรักษา : {$payment_detail.indication_admit}
					</td>
				</tr>
				<tr>
					<td colspan="4">&nbsp;</td>
				</tr>
				<tr>
					<td colspan="4" align="center">
						<input type="button" onclick="window.open('{$APP_URL}/printpayment/{$paymentId}','_blank')" value="Print" style="width:180px; height: 30px; font-size: 16px;">
					</td>
				</tr>
				<tr>
					<td colspan="4">&nbsp;</td>
				</tr>
			</table>
			
		</div>
		
	</div>
{include file="$g_template/_frontfoot.tpl"}